package com.coolwen.dao;

import com.coolwen.entity.*;

import java.util.List;
import java.util.Map;

/**
 * Created by user on 2016/7/29.
 */
public interface OrdersMapper {

    int deleteByPrimaryKey(Integer id);

    int insert(Orders record);

    int insertSelective(Orders record);

    Orders selectByPrimaryKey(Integer id);

    int updateByPrimaryKeySelective(Orders record);

    int updateByPrimaryKey(Orders record);

    List<Orders> find(Map<String, Object> params);
    //   List<User> find(@Param("name") String name);


    Orders load(Integer id);


    List<Orders> find_by_user(Map<String, Object> params);

    List<Orders> find_by_status(Map<String, Object> params);

    int find_by_user_count(Map<String, Object> params);

    int find_by_status_count(Map<String, Object> params);

    void add(Orders orders, User user, int aid, List<CartProduct> cps);
}
